package com.cy.server.controller;

import com.cy.server.pojo.Admin;
import com.cy.server.pojo.RespBean;
import com.cy.server.service.IAdminService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @peoject: yeb
 * @description: 在线聊天
 * @author: LiShaoZhuo
 * @create: 2021-05-10 16:09
 **/
@RestController
@RequestMapping("/chat")
public class ChatController {

    @Autowired
    IAdminService adminService;

    @ApiOperation("获取所有操作员")
    @PostMapping("/admin")
    public List<Admin> selectAllAdmins(String keywords){
        return adminService.getAllAdmins(keywords);
    }
}
